package com.ruoyi.project.technical.technical.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.project.technical.technical.mapper.TechnicalCaseMapper;
import com.ruoyi.project.technical.technical.domain.TechnicalCase;
import com.ruoyi.project.technical.technical.service.ITechnicalCaseService;
import com.ruoyi.common.utils.text.Convert;

/**
 * 技术案例库Service业务层处理
 * 
 * @author ruoyi
 * @date 2024-04-29
 */
@Service
public class TechnicalCaseServiceImpl implements ITechnicalCaseService 
{
    @Autowired
    private TechnicalCaseMapper technicalCaseMapper;

    /**
     * 查询技术案例库
     * 
     * @param id 技术案例库主键
     * @return 技术案例库
     */
    @Override
    public TechnicalCase selectTechnicalCaseById(Long id)
    {
        return technicalCaseMapper.selectTechnicalCaseById(id);
    }

    /**
     * 查询技术案例库列表
     * 
     * @param technicalCase 技术案例库
     * @return 技术案例库
     */
    @Override
    public List<TechnicalCase> selectTechnicalCaseList(TechnicalCase technicalCase)
    {
        return technicalCaseMapper.selectTechnicalCaseList(technicalCase);
    }

    /**
     * 新增技术案例库
     * 
     * @param technicalCase 技术案例库
     * @return 结果
     */
    @Override
    public int insertTechnicalCase(TechnicalCase technicalCase)
    {
        return technicalCaseMapper.insertTechnicalCase(technicalCase);
    }

    /**
     * 修改技术案例库
     * 
     * @param technicalCase 技术案例库
     * @return 结果
     */
    @Override
    public int updateTechnicalCase(TechnicalCase technicalCase)
    {
        return technicalCaseMapper.updateTechnicalCase(technicalCase);
    }

    /**
     * 批量删除技术案例库
     * 
     * @param ids 需要删除的技术案例库主键
     * @return 结果
     */
    @Override
    public int deleteTechnicalCaseByIds(String ids)
    {
        return technicalCaseMapper.deleteTechnicalCaseByIds(Convert.toStrArray(ids));
    }

    /**
     * 删除技术案例库信息
     * 
     * @param id 技术案例库主键
     * @return 结果
     */
    @Override
    public int deleteTechnicalCaseById(Long id)
    {
        return technicalCaseMapper.deleteTechnicalCaseById(id);
    }
}
